import Counter from '../components/Counter';
import { connect } from 'react-redux';
import { increment, decrement, incrementIfOdd, incrementAsync } from '../actions';

console.log('[containers/Connect2.js] =>react-redux.connect');

export default connect(
    state => ({ counter: state.counter }),
    dispatch => ({
        increment: () => dispatch(increment()),
        decrement: () => dispatch(decrement()),
        incrementIfOdd: () => dispatch(incrementIfOdd()),
        incrementAsync: () => dispatch(incrementAsync()),
    })
)(Counter);
